package Homework;

import java.util.Arrays;

public class demo1 {
    public static void transform(int[] arr) {
        for (int i = 0; i < arr.length; i++) {
            arr[i] *= 2;
        }
    }
    public static void main(String[] args) {
        int[] arr = {1, 2, 3};
        System.out.println("修改前的数组"+Arrays.toString(arr));
        transform(arr);
        System.out.println("修改后的数组"+Arrays.toString(arr));
    }
}
